Black Friday Sale Upgrade Your Home β†’

Install AWS Cloud Development Kit (CDK) and create a new project

We'll start by installing the AWS Cloud Development Kit.

  • npm install -g aws-cdk

-g stands for global (meaning that once installed, this package will be available anywhere on your computer)

πŸ‘ Throughout the course, Hanii will use both yarn and npm package mangers, and it's really up to you to decide which one to use, as both work fine.

Verify thatcdk was installed.

  • cdk --version

Initialize a new cdk project.

  • cdk init
BASH
* sample-app: Example CDK Application with some constructs
└─ cdk init sample-app --language=[csharp|fsharp|java|javascript|python|typescript]

We are going to choose the sample app, typescript template:

  • cdk init sample-app --language=typescript

This will create a bunch of files with the following directory structure (note that I'm displaying files just one level deep here):

BASH
.
β”œβ”€β”€ .git
β”œβ”€β”€ .gitignore
β”œβ”€β”€ .npmignore
β”œβ”€β”€ README.md
β”œβ”€β”€ bin
β”œβ”€β”€ cdk.json
β”œβ”€β”€ jest.config.js
β”œβ”€β”€ lib
β”œβ”€β”€ node_modules
β”œβ”€β”€ package-lock.json
β”œβ”€β”€ package.json
β”œβ”€β”€ test
└── tsconfig.json

πŸ‘ You can run tree -la 1 to display the tree.

Β Β PreviousΒ Β Β  Β Β Next